

import { Component } from 'react'//直接继承react的component而不是taro的component
import { View } from '@tarojs/components'
import { AtTabs, AtTabsPane } from 'taro-ui'
import {SpecialRecruit} from'../../components'

export default class Tabs extends Component {
  state={
    current:0,
  }
  handleClick (value) {
    this.setState({
      current: value
    })
  }
  render () {
    const tabList = [{ title: '专场招聘' }, { title: '职业选择' }, { title: '企业选择' }]
    return (
      <AtTabs current={this.state.current} tabList={tabList} onClick={this.handleClick.bind(this)}>
        <AtTabsPane current={this.state.current} index={0} >
          <SpecialRecruit />
        </AtTabsPane>
        <AtTabsPane current={this.state.current} index={1}>
          <View style='padding: 100px 50px;background-color: #FAFBFC;text-align: center;'>标签页二的内容</View>
        </AtTabsPane>
        <AtTabsPane current={this.state.current} index={2}>
          <View style='padding: 100px 50px;background-color: #FAFBFC;text-align: center;'>标签页三的内容</View>
        </AtTabsPane>
      </AtTabs>
    )
  }
}